Repository navigation
fix: reject loader versions that are not versions - #20
Merged
Merged
Conversation
A real run with "--loader-version <version>" (a placeholder copied from an example) wrote a .mrpack declaring fabric-loader "<version>", which no launcher can install. The option, target.loaderVersion in the config and the web UI now check the format (letters, digits and . + _ -) before any request, without claiming to check that the version exists.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Found during a real run.
Problem
migrate --loader-version <version>, with the placeholder copied as-is from an example, wrote a.mrpackthat declaredfabric-loader: "<version>". No launcher can install that pack.Fix
A format check (letters, digits and
. + _ -, starting with a letter or digit, 64 characters max) now applies to:--loader-version, before any request and before any file is written;target.loaderVersioninmodshift.config.json;It doesn't claim to check that the version exists, only that it looks like one:
0.16.5,21.1.77,47.3.0and0.27.1-beta.1are accepted.Tests cover the format, the config, and the real case (exit code 1, no request sent, no file written). CHANGELOG updated.
Checks
lint, format, typecheck, build and the docs diff are clean. 437 tests pass.
Note: this PR and #19 both add a "Fixed" line to the CHANGELOG. I'll resolve the small conflict on whichever is merged second.
Generated by Claude Code